﻿@{
    Bundle("base");
    string html_dir = "unknown";
    if(JDM.HasFlags(Svc.Localization.Language.Flags, "LTR"))
    {
        html_dir = "ltr";
    }
    else if(JDM.HasFlags(Svc.Localization.Language.Flags, "RTL"))
    {
        html_dir = "rtl";
    }
}

<!DOCTYPE html>
<html class="@Request.Browser.Platform.ToLowerInvariant() @Request.Browser.Type.ToLowerInvariant() @html_dir" dir="@html_dir">
    <head>
        <!-- Powered by Xenta Framework. Know more at http://xenta.net. -->
        <title>@T(Res.Name("Title"), ViewBag.PageTitle, Svc.Context.Infrastructure)</title>
        <link rel="shortcut icon" href="@Url.Theme("Images/logo.ico")" />
        @{
            Html.RenderPartial("_Bundles");
            Html.RenderPartial("_Analytic");
        }
    </head>
    <body>
        <section class="page">
            @RenderBody()
            @{
                Html.RenderPartial("_Status", ViewData.ModelState);
            }
        </section>
    </body>
</html>
@if(Svc.Config(Par.In("WebPortal").Name("DebugMode"), Context.IsDebuggingEnabled))
{
    @:<!-- MODEL DUMP
    @Html.Raw(Model)
    @:-->
}